#include <iostream>
#include <string>

#include "inheritance.h"
using namespace std;

void MainAlgorithm::print_info(){
    cout << "Printing the algo info " << endl;
    cout << "The name is  " << (this->name)<< endl;
    cout << "The O(n) is "<< MainAlgorithm::On << endl;
}

int MainAlgorithm::computation(){
    cout << "I was called in main class computing ..." << endl;
    return 1;

}

void MainAlgorithm::set_values(string n,string o){
    this -> name = n;
    this -> On = o;
}

int BetterAlgorithm::computation(){
    int temp;
    cout << "I was called in the child onne im better " << endl;
    
    temp = MainAlgorithm::computation();

    //sacma sapan islemler iste :)
    return (temp+1);
}
